<!DOCTYPE html>
<html>
<head>
    <title>Break Statement Example 1</title>
    <script type="text/javascript">
        var num = 0;
        
        for (var i=1; i < 10; i++) {
            if (i % 5 == 0) {
                break;
            }
            num++;
        }
        
        alert(num);    //4



    </script>
</head>
<body>

</body>
</html>